package com.ssl.mall.member.controller;


import com.ssl.mall.common.bean.Result;
import com.ssl.mall.member.entity.Member;
import com.ssl.mall.member.feign.CouponFeignService;
import org.springframework.beans.factory.annotation.Autowired;
import org.springframework.web.bind.annotation.GetMapping;
import org.springframework.web.bind.annotation.RequestMapping;

import org.springframework.web.bind.annotation.RestController;

/**
 * <p>
 * 会员 前端控制器
 * </p>
 *
 * @author ssl
 * @since 2021-07-18
 */
@RestController
@RequestMapping("/member/member")
public class MemberController {

    @Autowired
    private CouponFeignService couponFeignService;

    @GetMapping("coupons")
    public Result coupons(){
        Member member = new Member();
        member.setNickname("施森林");
        return Result.ok().put("member", member).put("couons", couponFeignService.memberCoupons().get("coupons"));
    }
}

